//
//  MSOtherEntriesCell.m
//  觅尚
//
//  Created by No.8 on 2019/4/7.
//  Copyright © 2019 No.8. All rights reserved.
//

#import "MSOtherEntriesCell.h"

@implementation MSOtherEntriesCell

+ (instancetype)cellWithTableView:(UITableView *)tableView{
    MSOtherEntriesCell * cell = [tableView dequeueReusableCellWithIdentifier:[MSOtherEntriesCell ID]];
    cell = [[MSOtherEntriesCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:[MSOtherEntriesCell ID]];
    cell.backgroundColor = backgroundcolor;
    return cell;
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self setMember];
        
    }
    return self;
}
- (void)setMember{
    /** 时间*/
    self.NameLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 40 * px, ScreenWidth / 3, 60 * px)];
    self.NameLabel.textColor = [UIColor whiteColor];
    self.NameLabel.text = @"xxxxx";
    self.NameLabel.textAlignment = NSTextAlignmentCenter;
    self.NameLabel.font = [UIFont systemFontOfSize:SYRealValue(28 / 2)];
    [self addSubview:self.NameLabel];
    
    
    /** 房间*/
    self.MoneyLabel = [[UILabel alloc] initWithFrame:CGRectMake(ScreenWidth / 3, self.NameLabel.y, self.NameLabel.width, self.NameLabel.height)];
    self.MoneyLabel.textColor = WYCRGBColor(92, 201, 180);
    self.MoneyLabel.text = @"￥23287876";
    self.MoneyLabel.textAlignment = self.NameLabel.textAlignment;
    self.MoneyLabel.font = self.NameLabel.font;
    [self addSubview:self.MoneyLabel];
    
    
    
    
    
    /** 金额*/
    self.ModeLabel = [[UILabel alloc] initWithFrame:CGRectMake(ScreenWidth / 3 * 2, self.NameLabel.y, self.NameLabel.width, self.NameLabel.height)];
    self.ModeLabel.textColor = self.NameLabel.textColor;
    self.ModeLabel.text = @"微信";
    self.ModeLabel.textAlignment = self.NameLabel.textAlignment;
    self.ModeLabel.font = self.NameLabel.font;
    [self addSubview:self.ModeLabel];
    

    self.LinView = [[UIView alloc] initWithFrame:CGRectMake(0, CGRectGetMaxY(self.NameLabel.frame) + 40 * px, ScreenWidth, 1)];
    self.LinView.backgroundColor = BackViewColor;
    [self addSubview:self.LinView];
    
}

- (void)setOtherEntriesModel:(MSOtherEntriesModel *)OtherEntriesModel{
    _OtherEntriesModel = OtherEntriesModel;
    self.NameLabel.text = [NSString stringWithFormat:@"%@",OtherEntriesModel.pojectName];
    
    self.MoneyLabel.text = [NSString stringWithFormat:@"￥%@",OtherEntriesModel.incomeMoney];
    
    self.ModeLabel.text = [NSString stringWithFormat:@"%@",OtherEntriesModel.payName];
    
}
+(NSString *)ID{
    return @"cell";
}

@end
